<template>
	<view class="um-textarea">
		<textarea :value="modelValue" @input="input" />
	</view>
</template>

<script lang="ts" setup>
	defineProps<{ modelValue : string }>()

	const emits = defineEmits(['update:modelValue', 'input'])

	const input = (e : any) => {
		emits('update:modelValue', e.detail.value)
		emits('input', e)
	}
</script>

<style lang="scss" scoped>
	.um-textarea {
		>textarea {
			box-sizing: border-box;
			width: 100%;
			padding: 16rpx;
			border: 1px solid #5677fc30;
		}
	}
</style>